package com.shy.mapper;

import com.shy.config.common.BaseQuery;
import com.shy.config.util.DataScope;
import com.shy.entity.Customer;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
* @author sunhuanyu
* @description 针对表【t_customer(客户表)】的数据库操作Mapper
* @createDate 2024-12-09 11:57:17
* @Entity com.shy.entity.Customer
*/
public interface CustomerMapper {

    int deleteByPrimaryKey(Long id);

    int insert(Customer record);

    int insertSelective(Customer record);

    Customer selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(Customer record);

    int updateByPrimaryKey(Customer record);

    @DataScope(tableAlias = "tc", tableField = "owner_id")
    List<Customer> queryCustomerList(BaseQuery baseQuery);

    @DataScope(tableAlias = "tc", tableField = "owner_id")
    List<Customer> queryCustomerByIds(@Param("baseQuery") BaseQuery baseQuery,@Param("ids") List<Integer> ids);

    Customer selectByid(Integer id);
}
